/*
 * Lenovo Group
 * Copyright (c) 2015-2016 All Rights Reserved.
 * Project Name: lmrp-android app
 * Create Time: 16-2-16 下午6:40
 */

package com.lenovo.mso2o.entity;

import android.os.Parcel;
import android.os.Parcelable;

import com.lenovo.mso2o.entity.g.Attachment;

/**
 * Created by hippo on 12/10/15.
 */
public class FAttachment extends Attachment implements Parcelable {

    public FAttachment() {
        setStatus(0);
        setFailedTime(0);
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeString(this.getTicketid());
        dest.writeInt(this.getStatus());
        dest.writeString(this.getPath());
        dest.writeString(this.getLazyId());
        dest.writeInt(this.getFailedTime());
    }

    public FAttachment(Parcel in) {
        this.setTicketid(in.readString());
        this.setStatus(in.readInt());
        this.setPath(in.readString());
        this.setLazyId(in.readString());
        this.setFailedTime(in.readInt());
    }

    public static final Creator<FAttachment> CREATOR = new Creator<FAttachment>() {
        public FAttachment createFromParcel(Parcel source) {
            return new FAttachment(source);
        }

        public FAttachment[] newArray(int size) {
            return new FAttachment[size];
        }
    };

}
